package ltd.newbee.mall.dto;

import lombok.Getter;
import lombok.RequiredArgsConstructor;
import lombok.Setter;
import lombok.ToString;
import org.hibernate.annotations.DynamicUpdate;

import java.math.BigDecimal;

/**
 * @ClassName: PurchaseDTO
 * @Description: 采购DTO 采购数据传输对象
 * @Author: Emily
 * @Date: 2021-09-03 11:01
 * @Version 1.0
 */

@Setter //生成set方法
@Getter //生成get
@RequiredArgsConstructor //生成有参构造器
@DynamicUpdate //自动更新时间
@ToString //测试时使用，上线后删除
public class PurchaseNewDTO
{
    /** 商品Id */
    private long goodsId;

    /**
     * 商品名称
     */
    private String goodsName;

    /** 数量 */
    private Integer productQuantity;

    /** 进货价 */
    private BigDecimal importPrice;

    /** 供货商ID */
    private String supplierId;

    public PurchaseNewDTO(long goodsId, Integer productQuantity, BigDecimal importPrice,String supplierId)
    {
        this.goodsId = goodsId;
        this.productQuantity = productQuantity;
        this.importPrice = importPrice;
        this.supplierId = supplierId;
    }
}
